#include "YoungLogon.h"
#include <QApplication>
#include <QtDebug>
#include <QResource>
#include <QMessageBox>
#include <QFile>
#include <QDir>
#include <QTextStream>
#include "Global.h"
#include "qqprotocol.h"

int main(int argc, char *argv[])
{


    QApplication a(argc, argv);



    QString resFilePath = QApplication::applicationDirPath()+"/res.rcc";
    if( QResource::registerResource(resFilePath) == false)
    {
        resFilePath = QApplication::applicationDirPath()+"/../../YoungQQ/res.rcc";
        if( QResource::registerResource(resFilePath) == false)
        {
            QMessageBox::information(NULL, "Error", "Resource file is not found!", QMessageBox::Yes );
        }
    }

 QQProtocol p;
 CVerifyCodeInfo v;
 p.CheckVerifyCode("584036", WEBQQ_APP_ID, &v);
 CLoginResult_1 l;
 p.Logon1("584036","123456pp", &v,&l);

    DlgLogon w;
    w.show();


    int iRet = a.exec();
    QResource::unregisterResource(resFilePath);
    return iRet;
}
